import Vue from 'vue'
import Router from 'vue-router'
// import HelloWorld from '@/components/HelloWorld'
import Login from '@/views/Login.vue'
import Home from '@/views/home/home.vue'
import empty from '@/views/empty.vue'

import newSafe from '@/views/safedeal/newSafe.vue'
import list from '@/views/safedeal/list.vue'
import dianwei from '@/views/safedeal/addSafe-dianwei.vue'
import yinhuan from '@/views/safedeal/addSafe-yinhuan.vue'
import tianjia from '@/views/safedeal/addSafe-tianjia.vue'
import shixian from '@/views/safedeal/addSafe-shixian.vue'

import chuli from '@/components/chuli.vue'
import shenhezhong from '@/components/shenhezhong.vue'
import wancheng from '@/components/wancheng.vue'

import detailsCL from '@/components/details/details-cl.vue'
import detailsSHZ from '@/components/details/details-sh-zhong.vue'
import detailsSH from '@/components/details/details-sh.vue'
import detailsWC from '@/components/details/details-wc.vue'
import resultCL from '@/components/details/result-cl.vue'
import resultSH from '@/components/details/result-sh.vue'

Vue.use(Router)

export default new Router({
    routes: [{
            path: '/',
            redirect: '/home'
        },
        {
            path: '/login',
            name: 'login',
            component: Login
        },
        {
            path: '/home',
            name: 'home',
            component: Home
        },
        // {
        //     path: '/newSafe',
        //     name: 'newSafe',
        //     component: newSafe
        // }, 
        {
            path: '/addsafe',
            name: 'empty',
            component: empty,
            redirect: '/addsafe/dianwei',
            children: [{
                    path: 'dianwei',
                    name: 'dianwei',
                    component: dianwei,
                },
                {
                    path: 'yinhuan',
                    name: 'yinhuan',
                    component: yinhuan,
                },
                {
                    path: 'tianjia',
                    name: 'tianjia',
                    component: tianjia,
                },
                {
                    path: 'shixian',
                    name: 'shixian',
                    component: shixian,
                }
            ]
        },

        {
            path: '/list',
            name: 'empty',
            component: empty,
            redirect: '/list/index',
            children: [{
                    path: 'index',
                    name: 'list',
                    component: list,
                },
                {
                    path: 'chuli',
                    name: 'chuli',
                    component: chuli,
                },
                {
                    path: 'shenhezhong',
                    name: 'shenhezhong',
                    component: shenhezhong,
                },
                {
                    path: 'wancheng',
                    name: 'wancheng',
                    component: wancheng,
                }
            ]
        }, {
            path: '/details-cl',
            name: 'detailsCL',
            component: detailsCL
        }, {
            path: '/details-sh-zhong',
            name: 'detailsSHZ',
            component: detailsSHZ
        }, {
            path: '/details-sh',
            name: 'detailsSH',
            component: detailsSH
        }, {
            path: '/details-wc',
            name: 'detailsWC',
            component: detailsWC
        }, {
            path: '/result-cl',
            name: 'resultCL',
            component: resultCL
        }, {
            path: '/result-sh',
            name: 'resultSH',
            component: resultSH
        }
    ]
})